Skip to main content

All Tokens

Queries all tokens associated with a factory contract for a specific chain UID.

query All_tokens($chainUid: String!, $limit: Int, $offset: Int) {
factory(chain_uid: $chainUid) {
all_tokens(limit: $limit, offset: $offset) {
tokens
pagination {
total_count
limit
offset
}
}
}
}

Example

curl --request POST \
--header 'content-type: application/json' \
--url 'https://testnet.api.euclidprotocol.com/graphql' \
--data '{"query":"query All_tokens($chainUid: String!, $limit: Int, $offset: Int) {\n factory(chain_uid: $chainUid) {\n all_tokens(limit: $limit, offset: $offset) {\n tokens\n pagination {\n total_count\n limit\n offset\n }\n }\n }\n}","variables":{"chainUid":"nibiru","limit":7,"offset":null}}'

Open in Playground

Arguments

  • chainUid (String!): The unique identifier of the chain.
  • limit (Int): Optional limit to the number of results to return.
  • offset (Int): Optional number of tokens to skip before starting to return the result set. Used for pagination.

Return Fields

FieldTypeDescription
tokens[String]The list of tokens.
total_countIntThe total number of token pairs (pools) available.
limitIntThe maximum number of pools returned per request.
offsetIntThe number of pools to skip before starting to return the result set.